import baseRequest from './request'

//登录
export function Login({ data = {}, hasLoading = true } = {}) {
    return baseRequest({
        url: '/Member/Login',
        method: 'POST',
        needLogin: false,
        data,
        hasLoading
    })
}

//注册
export function Register({ data = {}, hasLoading = true } = {}) {
    return baseRequest({
        url: '/Member/Register',
        method: 'POST',
        needLogin: false,
        data,
        hasLoading
    })
}

//获取个人资料详情
export function GetLoginUser({ data = {}, hasLoading = true } = {}) {
    return baseRequest({
        url: '/Member/GetLoginUser',
        method: 'GET',
        needLogin: true,
        data,
        hasLoading
    })
}

//更改手机号
export function UpdatePhone({ data = {}, hasLoading = true } = {}) {
    return baseRequest({
        url: '/Member/UpdatePhone',
        method: 'POST',
        needLogin: true,
        data,
        hasLoading
    })
}

export function Search({ data = {}, hasLoading = true } = {}) {
    return baseRequest({
        url: '/Member/Search',
        method: 'POST',
        needLogin: true,
        data,
        hasLoading
    })
}

//代注册
export function HelpRegister({ data = {}, hasLoading = true } = {}) {
    return baseRequest({
        url: '/Member/HelpRegister',
        method: 'POST',
        needLogin: true,
        data,
        hasLoading
    })
}

export function UpdateInfo({ data = {}, hasLoading = true } = {}) {
    return baseRequest({
        url: '/Member/UpdateInfo',
        method: 'POST',
        needLogin: true,
        data,
        hasLoading
    })
}

export function SendCode({ data = {}, hasLoading = true } = {}) {
    return baseRequest({
        url: '/Member/SendCode',
        method: 'GET',
        needLogin: true,
        data,
        hasLoading
    })
}


